package com.hxzy.controller.admin.dict.resp;

import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.hxzy.common.annotates.DictTypeProperty;
import com.hxzy.common.enums.DictTypeEnum;
import com.hxzy.common.exsyexcel.DictDataConvert;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

import java.util.Date;

@Getter
@Setter
@ApiModel(value = "数据字典模型")
public class DictTypeResp {

    @ExcelProperty(value = "主键")
    @ApiModelProperty(value = "主键")
    private Long id;

    /**
     * 字典名称
     */
    @ExcelProperty(value = "字典名称")
    @ApiModelProperty(value = "字典名称")
    private String dictName;

    /**
     * 字典类型
     */
    @ExcelProperty(value = "字典类型")
    @ApiModelProperty(value = "字典类型")
    private String dictType;

    /**
     * 状态（0正常 1停用）
     */
    @DictTypeProperty(value = DictTypeEnum.SYS_NORMAL_DISABLE)
    @ExcelProperty(value = "状态",converter = DictDataConvert.class)
    @ApiModelProperty(value = "状态（0正常 1停用）")
    private String status;

    /**
     * 创建时间
     */
    @ExcelProperty(value = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @ApiModelProperty(value = "创建时间")
    private Date createTime;

    /**
     * 备注
     */
    @ExcelProperty(value = "备注")
    @ApiModelProperty(value = "备注")
    private String remark;
}
